#include <iostream>

using namespace std;

int main(void)
{
	int i, j;
	double num, sum, n;
	double num1, num2;

	cout << "n: ";
	cin >> n;

	cout << 1 << ": ";
        cin >> num;
	num1 = num;
	num2 = num;
	sum = num;

	for(i = 2; i <= n; i ++)
	{
		cout << i << ": ";
		cin >> num;
		if (num >= num1)
			num1 = num;
		if (num <= num2)
			num2 = num;
		sum = sum + num;
//		cout << "sum = " << sum << endl;
	}

	cout << "最大值: " << num1 << endl;
	cout << "最小值: " << num2 << endl;
	cout << "平均值: " << sum / n << endl;

	return 0;
}
